#include <stdio.h>

int main(int argc, char *argv[])
{
	int n;
	scanf("%d", &n);

	printf("8\n");
	printf("%d\n", (n-2)*12);
	printf("%d\n", (n-2)*(n-2)*6);

	return 0;
}
